# -*- coding: utf-8 -*-
from db.mysql import MysqlClient
from common.helper import Helper
class Arrangement( object ):
    def __init__(self):
        self.mysql = MysqlClient()
        self.name = "信泰i立方恶性肿瘤疾病保险"

    def pullData(self, data={}):
        for item in Helper.selectData(self.name, self.mysql):

            data["name"] = self.name
            data["company"] = "信泰保险"
            data["year"] = item["year"]
            data["gender"] = "0" if item["gender"] == "F" else "1"
            data["expire"] = item["expire"]
            data["money"] = str(int(int(item["money"])/10000)) + "w"
            data["payType"] = "年交"
            data["interval"] = item["interval"]
            data["price"] = item["price"]
            Helper.mergeTable( self.name,self.mysql,data)
